package com.pojo;

import com.annotation.*;

/**
 * @author 代廷波
 * @className: User
 * @description:
 * @create 2018/11/13 0013-9:24
 **/
@Table("t_user")
public class User {

    @Column("id")
    private int id;

    @Column("user_name")
    private String userName;

    @Column("addr_det")
    private String addrDet;




    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getAddrDet() {
        return addrDet;
    }

    public void setAddrDet(String addrDet) {
        this.addrDet = addrDet;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        User user = (User) o;

        if (id != user.id) return false;
        if (userName != null ? !userName.equals(user.userName) : user.userName != null) return false;
        return addrDet != null ? addrDet.equals(user.addrDet) : user.addrDet == null;
    }

    @Override
    public int hashCode() {
        int result = id;
        result = 31 * result + (userName != null ? userName.hashCode() : 0);
        result = 31 * result + (addrDet != null ? addrDet.hashCode() : 0);
        return result;
    }
}
